import pydantic_settings

import lib.app.split_settings.utils as app_split_settings_utils


class RedisSettings(pydantic_settings.BaseSettings):
    """Redis Settings."""

    model_config = pydantic_settings.SettingsConfigDict(
        env_file=app_split_settings_utils.ENV_PATH,
        env_prefix="REDIS_",
        env_file_encoding="utf-8",
        extra="ignore",
    )

    # Connection settings
    host: str = "localhost"
    port: int = 6379
    db: int = 0
    CACHE_EXPIRE: int = 60 * 60 * 3  # 3 hours
